package com.astro.app;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;
import org.springframework.core.env.Environment;

@Configuration
@PropertySource("classpath:spring-server-config.properties")
public class AppConfig {
   @Autowired
   Environment env;

   public String getCSVPath() {
       return env.getProperty("csv.path");
   }
 
   public String getTempPath(){
	   return getProp("pdf.temp.path");
   }
   
   public String getTemplatePath(){
	   return getProp("pdf.template.path");
   }

   public String getProp(String propName) {
       return env.getProperty(propName);
   }
}